<?php
require('lib/verify.php');
require('lib/has_char.php');
require('lib/is_approved.php');

$_category = "warmath";
$_title = "Characters";
require('lib/head.php');

boxTop("Warmath: $_title");
?>
<?php
$sql = "select * from wm_characters where character_system_id='" . $system["system_id"] . "' and character_approved = 1 order by character_class asc, character_name asc";
$result = $db->query($sql);

while($chara=$db->fetch_assoc($result)) {
  $sql = "select * from wm_wishes where wish_character = '" . $chara["character_id"] . "'";
  $res = $db->query($sql);
  $num = $db->num_rows($res);
?>
<?cclass($chara["character_class"])?> <a href="character.php?id=<?=$chara["character_id"]?>"><?=$chara["character_name"]?></a><? if($num) { ?> (<a href="wishlist-other.php?id=<?=$chara["character_id"]?>"><?=$num?> wishes</a>)<?php } ?><br />
<?php
}

?>

<?php
boxBot();
?>

<?php
require('lib/foot.php');
?>

